import request from '@/utils/request'

// 物流商API管理-列表
export const logisticsApiList = data =>
  request({
    url: `/api/logistics/index`,
    method: 'post',
    data,
  })

// 物流商信息-获取渠道列表
export const logisticsChannel = params =>
  request({
    url: `/logistics/logistics/channel`,
    method: 'get',
    params,
  })

// 物流商API管理-创建
export const createLogisticsApi = data =>
  request({
    url: `/api/logistics/create`,
    method: 'post',
    data,
  })

// 物流商API管理-详情
export const logisticsApiDetail = params =>
  request({
    url: `/api/logistics/detail`,
    method: 'get',
    params,
  })

// 物流商API管理-编辑
export const updateLogisticsApi = data =>
  request({
    url: `/api/logistics/update`,
    method: 'post',
    data,
  })

// 物流商API管理-启用禁用
export const logisticsApiStatus = data =>
  request({
    url: `/api/logistics/status`,
    method: 'post',
    data,
  })

// 物流商运输方式管理-列表
export const logisticsShipping = data =>
  request({
    url: `/api/logistics-shipping/index`,
    method: 'post',
    data,
  })

// 物流商运输方式管理-启用禁用
export const logisticsShippingStatus = data =>
  request({
    url: `/api/logistics-shipping/status`,
    method: 'post',
    data,
  })

// 物流商运输方式管理-创建
export const createLogisticsShipping = data =>
  request({
    url: `/api/logistics-shipping/create`,
    method: 'post',
    data,
  })

// 物流商运输方式管理-详情
export const logisticsShippingDetail = params =>
  request({
    url: `/api/logistics-shipping/detail`,
    method: 'get',
    params,
  })

// 物流商运输方式管理-编辑
export const updateLogisticsShipping = data =>
  request({
    url: `/api/logistics-shipping/update`,
    method: 'post',
    data,
  })

//同步物流商运输方式
export const logisticsShippingSync = data =>
  request({
    url: `/api/logistics-shipping/sync`,
    method: 'post',
    data,
  })
  //获取物流商数据
export const logisticsList = (data) =>
request({
  url: `/opts/logistics`,
  method: "post",
  data,
});
